package com.secfound.soccer.server.tools;

import com.secfound.soccer.shared.db.Bet;
import com.secfound.soccer.shared.db.Game;

/**
 * Checks if a score guess is correct
 * @author alfonso.ayala
 *
 */
public class ScoreValidator {
	public static boolean check(Game realGame, Bet bet) {
		boolean result=false;
		if(realGame!=null){
			if(realGame.getaScore().equals( bet.getaScore() )
					&& realGame.getbScore().equals( bet.getbScore())
					&& realGame.getaTeam().equals(bet.getaTeam())
					&& realGame.getbTeam().equals(bet.getbTeam())	
					){
				result=true;
			}
		}
		return result;		
	}
}
